<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta name="author" content="lijun; 67086071; zwlijun@qq.com" />
<title> New Document </title>
<script src="../core.js" type="text/javascript"></script>
<script src="md5.js" type="text/javascript"></script>
<script src="sha1.js" type="text/javascript"></script>
<script src="sha256.js" type="text/javascript"></script>
<script src="base64.js" type="text/javascript"></script>
<script src="rsa.js" type="text/javascript"></script>
</head>

<body>
<script type="text/javascript">
var str = "abc";
//console.info(str.md5())
//console.info(str.sha1())
//console.info(str.sha256())
//console.info(XLib.Base64.encode("ripemd160.js"))
//console.info(XLib.Base64.decode("cmlwZW1kMTYwLmpz"))
//setMaxDigits(19);
// Put this statement in your code to create a new RSA key with these parameters
//var key = new RSAKeyPair(
// "e8527436a9b497a626eaf29f203d0db",
// "140cc6c1dd51873201b489c2c51f83db",
// "46bef44d1d3466fc89215c7b1b3e2be9"
//);
//var enc = XLib.RSA.encrypt(key, str);
//console.info(enc)
//console.info(XLib.RSA.decrypt(key, enc))


/*
setMaxDigits(131);
// Put this statement in your code to create a new RSA key with these parameters
key = new RSAKeyPair(
 "21aba4864c2ba037a6f44589a33af9da0209e01bc4dd1e36c172d82200035f5261a70ac6d06dfed55e30e07a3c65030b59781472b6539f8f288ceef042fef1ff82deb457a264d2fc160c077f3e937a8ebd8000cb9c8eb9289e72b8ed126b844ee7580774810e9746f3eb35a8d1cee815949a653af850afd93aa86b2a3851c7f",
 "a9c7e64a86a15985f4c6547f2661fe28adfae4cec95e1bdd93275c44653f2841eda2c7077ac5e8c1ca18060430b7b326f8b13a496b3588a1ac8f8f0a553f1abb0aa686f499731975fd0cbeefb97616aa10a8b3d970e5216ab644701930b910de7cd9ebed99bd6a75be9d3b2f45e58f53b04477820dd8b8fcbae8732255b15f",
 "67c2d1840a03c20069dc47f958d3041e976de2c47e04a2de8dda45c732042b1ec434b538c0da1db7157ffedf25f61e533885cec0ce96a69808e3e38fcebf7a87d3e7d7a485298751436b16410b70556d6135c1dc717879e57726f359322828f010cbf5fb98f2e1c0f31a52f289a8cd5808d5dbbb9130b7582a0a11e4f258e2f"
);
*/

setMaxDigits(131);
// Put this statement in your code to create a new RSA key with these parameters
var key = new RSAKeyPair(
 "10001",
 "",
 "B293AAC4108FF8637D9ECE9E064E8CE8F7728F914BBB2A3C5343733C63B7C51D98F7B2A8B5734E87E8F006F364CB54A80857783694F6515EB948871477EC4090EA11B7DF048016369ABD983256ACB9E80940727813B617FC7F3385415954682BB5E163FF8F3C62C10AE61FAB2980DDA4301BDA6DAA82307CC1D8D4A585F57D05"
);
var enc = XLib.RSA.encrypt2(key, "123456");
console.info(">>>" + enc)
//console.info(">>>" + XLib.RSA.decrypt2(key, enc))
</script>
</body>
</html>
